home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Complete Linux
/
Complete Linux.iso
/
xwindows
/
demos
/
xfract_1.z
/
xfract_1
/
xfractint-1.06
/
fractsrc.doc
< prev
next >
Wrap
Text File
|
1992-09-28
|
17KB
|
418 lines
The source code for Fractint is freely available.
Enhancements to it are appreciated. If you want to add something to
Fractint and join the Stone Soup Group, please do! To submit changes,
see "Contacting the Authors" in Fractint's online help.
Copyright Information:
======================
Some parts of the source are from the public domain and are not
copyrighted.
Some parts of the source bear explicit copyright notices from the
author and are subject to the conditions listed there by the author.
The remainder of the source (not already public domain, no explicit
author's copyright notice) is Copyright 1990, 1991 by the Stone Soup Group
(a loosely associated and ever-growing group of fanatic programmers).
The source code may be copied freely and may be used in other programs
under the following conditions:
It may not be used in a commercial program which produces fractal images.
Please credit the author (in general, credit Fractint and the Stone Soup
Group) as the source of the code.
Distribution of modified versions of Fractint:
==============================================
If you enhance Fractint and want to distribute the results to others, the
preferred approach is to join the Stone Soup Group - send us your
enhancements and get your name in lights in future versions of Fractint.
We prefer that a modified Fractint executable program not be distributed to
others, but understand that you might want to give copies to friends. This
is permitted, under the following conditions:
o The modified executable has a different name than "fractint.exe".
o The distribution includes a full unmodified copy of the corresponding
original version of fraint.exe. (The easiest way is to copy fraint.exe
to yournew.exe, then "pkzip -a fraint.exe newfract.exe" to add your
version, and perhaps add a read.me file to describe it.)
o The heading displayed by the modified program clearly indicates that
it is a non-standard release. E.g. you might change the heading to
say "Non-standard Fractint, Modified by John Doe".
o All author credits and distribution information in the online help
are unchanged (adding lines for your work is of course ok.)
The source code for a modified version of Fractint may not be distributed.
(This is because we don't want any chance of confusion over which version
of a source file is the official release.)
Compiling Fractint:
===================
FRASRC.EXE includes the complete source code for FRACTINT (.C and .ASM).
Recognizing that not everyone HAS (or even wants) an assembler, much less
either MASM 5.1 or Turbo-ASM, which are the only two assemblers that the
authors are aware of that can handle these particular files, it also contains
a complete set of .OBJ files from the assembler code,
The distributed source will not compile to exactly match the Fractint
release - it compiles with a different version number and heading.
The Microsoft 6.00A C compiler and Microsoft 5.1 assembler are used for
Fractint releases, so that is the one combination of compiler/assembler
which is pretty much guaranteed to handle FRACTINT in all of its various
mutations.
Given that several of FRACTINT's co-authors now prefer (or only have!)
alternate combinations, we have re-arranged the code to (usually) handle
several popular alternatives. In particular:
Microsoft C 6.00A and MASM 5.1:
-------------------------------
Just run MAKEFRAC.BAT, which invokes the Microsoft NMK utility using the
files FRACHELP.MAK, FRACTINT.MAK, and FRACTINT.LNK. Note that the assembler
.OBJ files have been included in the .ZIP file, so that you don't really
need MASM unless you are going to modify one or more of them. If you ARE
going to modify one of the assembler files, note that the distributed
versions rely on some nifty features added to version 5.1 (like the '.model
medium,c' option) and will not assemble under older versions of MASM without
a LOT of work.
Note that C 6.00 (the original release) had some problems. We never used it
for a Fractint release. If you don't have the fixed version (6.00A) you
should compile parser.c, loadfile.c, and calcfrac.c with no optimization,
using the /qc option. There might be other problems, those are the only
ones we're aware of...
Warning: FRACTINT.MAK uses C6.00A's most aggressive optimizations. It is
assumed there is no aliasing. See Microsoft's documentation on the /Oa
and /Oz options.
Microsoft C 5.1:
----------------
Edit MAKEFRAC.BAT: comment out the two "nmk ..." lines and uncomment
the lines for C5.1. Then run MAKEFRAC.
Quick-C:
--------
FRACTINT is just too big for the interactive Quick-C (QC) environment.
You have to use the command-line variant of Quick-C (QCL).
Edit MAKEFRAC.BAT: comment out the two "nmk ..." lines and uncomment
the lines for QuickC. Then run MAKEFRAC.
We're not sure all versions of QuickC work. 2.01 works as of
Fractint version 16. Depending on how much memory you have available,
you may have to manually compile some modules without the /O option.
Turbo-C, Turbo-C++ and TASM
---------------------------
Sorry, Turbo-C fans, but since version 14.0, FRACTINT requires TC++.
The lack of initialized FAR arrays and structures just did the older Turbo-C
product in. The *good* news is that some of the FRACTINT authors now
use Turbo-C++, so the odds of released FRACTINT distributions that do
not compile with Turbo products are lower than they used to be.
A FRACTINT.PRJ file is included for Turbo-C users.
With TC++ you'll have to do a manual step for the help system each time you
create a new fractint.exe - see notes in next section.
Help System
===========
You'll need to set up the help files to get any online help from a modified
version of Fractint.
For MSC users the MAKEFRAC.BAT file contains the necessary steps, you don't
need to do anything special.
TC++ users should:
start by creating HC.EXE using the supplied HC.PRJ file
run "hc /c" to create the file FRACTINT.HLP
each time you create a new fractint.exe, afterward run "hc /a" to append
FRACTINT.HLP to the new FRACTINT.EXE
You don't need to understand the rest of this section unless you have a
problem.
The source for Fractint's help is in the files HELP.SRC, HELP2.SRC, HELP3.SRC,
HELP4.SRC, and HELP5.SRC. The format of these files is described in HC.DOC.
The program HC.C ("help compiler") is used to convert the help text into
the form Fractint uses at run time.
Running "hc /c" compiles HELPx.SRC. It produces the file HELPDEFS.H for
use when compiling Fractint, and the file FRACTINT.HLP.
Running "hc /a" appends the FRACTINT.HLP file to FRACTINT.EXE to make the
compiled help info available at run time.
Overlays
========
Note: generally you won't have to worry about this!
Only the addition of huge code (new overlays), or work which changes the
relationship between major components of Fractint, are likely to affect
the overlay structure. However, if you make changes in a module which has a
comment at the start saying it is an overlay, please follow the guidelines
for use of ENTER_OVLY and EXIT_OVLY described after the next paragraph.
Fractint uses the Microsoft Link overlay feature, to reduce the runtime
memory required (which would otherwise exceed what DOS can give it.)
Some caution is required with overlays. Those source modules which are
part of an overlay have a comment to indicate this at the start. See the
fractint.lnk file for the current overlay structure.
Some notes about overlays:
o The obvious one: control should not switch to different overlays
frequently, else Fractint will become sluggish. If the overlay structure
changes, a test from floppy disk with no disk caching is a good idea.
o The linker cannot detect indirect calls (e.g. thing=routinename;
(*thing)();) to an overlay. Routines in overlays should not be called
indirectly, except from within the same overlay.
o The overlay manager logic (inserted by the linker) does handle calls
from within one overlay to another - the new overlay is brought in
from disk (displacing the old one in memory), when the subroutine
finishes the old overlay is brought back